#ifndef APPMAIN_H
#define APPMAIN_H

#include "app\root.h"
#include "app\config.h"
#include "actions\actioninvoker.h"
#include "gui\gui.h"


namespace app
{
	class AppMain
	{
		Config config;
		Root root;		//DOCUMENT (Model)
		gui::Gui gui;	//VIEW -> DOCUMENT, invoker
		actions::ActionInvoker	invoker; //invoker (CONTROLLER) -> DOCUMENT

		public:
			AppMain();
			virtual ~AppMain();

            void init(int & argc, char * argv[]);
            int run();
            void done();


            gui::Gui& getGui() {return gui;}
            Config& getConfig() {return config;}
            Root& getRoot() {return root;}
			actions::ActionInvoker& getActionInvoker() {return invoker;}

		protected:

		private:
	};
}
#endif // APPMAIN_H
